package com.atguigu.gulimall.product.feign;

import com.atguigu.common.to.product.SkuReductionTo;
import com.atguigu.common.to.product.SpuBoundsTo;
import com.atguigu.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@Component
@FeignClient(value = "gulimall-coupon",path = "gulimall-coupon")
public interface CouponFeignService {

    /*json数据模型一致 可无需使用同一to*/
///gulimall-coupon/coupon/spubounds/save
    @PostMapping("/coupon/spubounds/save")
    R saveSpuBounds(@RequestBody SpuBoundsTo spuBoundsTo);

    @PostMapping("coupon/skufullreduction/saveSkuReduction")
    R saveSkuReduction(@RequestBody SkuReductionTo skuReductionTo);
}
